/**********************************************************************************************************************
 *
 * Project:    mGameEngine
 * File:       scenegamestate.h
 * Author:     karooolek
 * Created on: 2009-04-09
 *
 **********************************************************************************************************************/

#ifndef SCENEGAMESTATE_H_
#define SCENEGAMESTATE_H_

#include "gamestate.h"
#include "scene.h"

namespace mGameEngine
{
namespace Game
{

/**
 * Game state with single game scene.
 */
class SceneGameState : public GameState
{
protected:
    /**
     * Game state scene.
     */
    Scene *_scene;

public:
    /**
     * Create new game scene game state.
     */
    SceneGameState();

    /**
     * Create game state with specified game scene.
     * @param scene game scene.
     */
    SceneGameState(Scene *scene);

    /**
     * Destroy game scene state.
     */
    virtual ~SceneGameState();

    /**
     * Get game state scene.
     * @return game state scene.
     */
    Scene *getScene() const
    {
        return _scene;
    }

    /**
     * Set game state scene.
     * @param scene game state scene.
     */
    void setScene(Scene *scene)
    {
        _scene = scene;
    }

    /**
     * Begin game scene state.
     */
    virtual void begin();

    /**
     * End game scene state.
     */
    virtual void end();

    /**
     * Game scene state main loop.
     */
    virtual void idle();

    /**
     * Game scene state draw loop.
     */
    virtual void draw() const;
};

}
}

#endif // SCENEGAMESTATE_H_
